# This file is part of the Neper software package.
# Copyright (C) 2003-2024, Romain Quey.
# See the COPYING file in the top-level directory.

cmake_minimum_required(VERSION 3.0...3.10)
project(scotch)

add_definitions(-Wno-unused-parameter -Wno-sign-compare -Wno-missing-field-initializers -Wno-unused-variable -Wno-unused-function -Wno-unused-label -Wno-unused-but-set-variable -Wno-implicit-fallthrough -Wno-switch -Wno-uninitialized -Wno-unused-result -Wno-implicit-function-declaration -Wno-unknown-warning-option -Wno-free-nonheap-object -Wno-maybe-uninitialized)

add_library(scotch
src/libscotch/arch.c
src/libscotch/arch_build.c
src/libscotch/arch_build2.c
src/libscotch/arch_cmplt.c
src/libscotch/arch_cmpltw.c
src/libscotch/arch_deco.c
src/libscotch/arch_deco2.c
src/libscotch/arch_dist.c
src/libscotch/arch_hcub.c
src/libscotch/arch_mesh.c
src/libscotch/arch_sub.c
src/libscotch/arch_tleaf.c
src/libscotch/arch_torus.c
src/libscotch/arch_vcmplt.c
src/libscotch/arch_vhcub.c
src/libscotch/bgraph.c
src/libscotch/bgraph_bipart_bd.c
src/libscotch/bgraph_bipart_df.c
src/libscotch/bgraph_bipart_ex.c
src/libscotch/bgraph_bipart_fm.c
src/libscotch/bgraph_bipart_gg.c
src/libscotch/bgraph_bipart_gp.c
src/libscotch/bgraph_bipart_ml.c
src/libscotch/bgraph_bipart_st.c
src/libscotch/bgraph_bipart_zr.c
src/libscotch/bgraph_check.c
src/libscotch/bgraph_store.c
src/libscotch/common.c
src/libscotch/common_file.c
src/libscotch/common_file_compress.c
src/libscotch/common_file_decompress.c
src/libscotch/common_integer.c
src/libscotch/common_memory.c
src/libscotch/common_string.c
src/libscotch/common_stub.c
src/libscotch/common_thread.c
src/libscotch/fibo.c
src/libscotch/gain.c
src/libscotch/geom.c
src/libscotch/graph.c
src/libscotch/graph_base.c
src/libscotch/graph_band.c
src/libscotch/graph_check.c
src/libscotch/graph_clone.c
src/libscotch/graph_coarsen.c
src/libscotch/graph_diam.c
src/libscotch/graph_dump.c
src/libscotch/graph_ielo.c
src/libscotch/graph_induce.c
src/libscotch/graph_io.c
src/libscotch/graph_io_chac.c
src/libscotch/graph_io_habo.c
src/libscotch/graph_io_mmkt.c
src/libscotch/graph_io_scot.c
src/libscotch/graph_list.c
src/libscotch/graph_match.c
src/libscotch/hall_order_hd.c
src/libscotch/hall_order_hf.c
src/libscotch/hall_order_hx.c
src/libscotch/hgraph.c
src/libscotch/hgraph_check.c
src/libscotch/hgraph_dump.c
src/libscotch/hgraph_induce.c
src/libscotch/hgraph_order_bl.c
src/libscotch/hgraph_order_cc.c
src/libscotch/hgraph_order_cp.c
src/libscotch/hgraph_order_gp.c
src/libscotch/hgraph_order_hd.c
src/libscotch/hgraph_order_hf.c
src/libscotch/hgraph_order_hx.c
src/libscotch/hgraph_order_kp.c
src/libscotch/hgraph_order_nd.c
src/libscotch/hgraph_order_si.c
src/libscotch/hgraph_order_st.c
src/libscotch/hmesh.c
src/libscotch/hmesh_check.c
src/libscotch/hmesh_hgraph.c
src/libscotch/hmesh_induce.c
src/libscotch/hmesh_mesh.c
src/libscotch/hmesh_order_bl.c
src/libscotch/hmesh_order_cp.c
src/libscotch/hmesh_order_gr.c
src/libscotch/hmesh_order_gp.c
src/libscotch/hmesh_order_hd.c
src/libscotch/hmesh_order_hf.c
src/libscotch/hmesh_order_hx.c
src/libscotch/hmesh_order_nd.c
src/libscotch/hmesh_order_si.c
src/libscotch/hmesh_order_st.c
src/libscotch/kgraph.c
src/libscotch/kgraph_band.c
src/libscotch/kgraph_check.c
src/libscotch/kgraph_map_bd.c
src/libscotch/kgraph_map_cp.c
src/libscotch/kgraph_map_df.c
src/libscotch/kgraph_map_ex.c
src/libscotch/kgraph_map_fm.c
src/libscotch/kgraph_map_ml.c
src/libscotch/kgraph_map_rb.c
src/libscotch/kgraph_map_rb_map.c
src/libscotch/kgraph_map_rb_part.c
src/libscotch/kgraph_map_st.c
src/libscotch/kgraph_store.c
src/libscotch/library_arch.c
src/libscotch/library_arch_f.c
src/libscotch/library_arch_build.c
src/libscotch/library_arch_build_f.c
src/libscotch/library_arch_dom.c
src/libscotch/library_arch_dom_f.c
src/libscotch/library_common_f.c
src/libscotch/library_geom.c
src/libscotch/library_geom_f.c
src/libscotch/library_graph.c
src/libscotch/library_graph_f.c
src/libscotch/library_graph_base.c
src/libscotch/library_graph_base_f.c
src/libscotch/library_graph_check.c
src/libscotch/library_graph_check_f.c
src/libscotch/library_graph_coarsen.c
src/libscotch/library_graph_coarsen_f.c
src/libscotch/library_graph_color.c
src/libscotch/library_graph_color_f.c
src/libscotch/library_graph_diam.c
src/libscotch/library_graph_diam_f.c
src/libscotch/library_graph_dump.c
src/libscotch/library_graph_induce.c
src/libscotch/library_graph_induce_f.c
src/libscotch/library_graph_io_chac.c
src/libscotch/library_graph_io_chac_f.c
src/libscotch/library_graph_io_habo.c
src/libscotch/library_graph_io_habo_f.c
src/libscotch/library_graph_io_mmkt.c
src/libscotch/library_graph_io_mmkt_f.c
src/libscotch/library_graph_io_scot.c
src/libscotch/library_graph_io_scot_f.c
src/libscotch/library_graph_map.c
src/libscotch/library_graph_map_f.c
src/libscotch/library_graph_map_io.c
src/libscotch/library_graph_map_io_f.c
src/libscotch/library_graph_map_view.c
src/libscotch/library_graph_map_view_f.c
src/libscotch/library_graph_order.c
src/libscotch/library_graph_order_f.c
src/libscotch/library_graph_part_ovl.c
src/libscotch/library_graph_part_ovl_f.c
src/libscotch/library_mapping.c
src/libscotch/library_memory.c
src/libscotch/library_memory_f.c
src/libscotch/library_mesh.c
src/libscotch/library_mesh_f.c
src/libscotch/library_mesh_graph.c
src/libscotch/library_mesh_graph_f.c
src/libscotch/library_mesh_io_habo.c
src/libscotch/library_mesh_io_habo_f.c
src/libscotch/library_mesh_io_scot.c
src/libscotch/library_mesh_io_scot_f.c
src/libscotch/library_mesh_order.c
src/libscotch/library_mesh_order_f.c
src/libscotch/library_order.c
src/libscotch/library_parser.c
src/libscotch/library_parser_f.c
src/libscotch/library_random.c
src/libscotch/library_random_f.c
src/libscotch/library_strat.c
src/libscotch/library_version.c
src/libscotch/library_version_f.c
src/libscotch/mapping.c
src/libscotch/mapping_io.c
src/libscotch/mesh.c
src/libscotch/mesh_check.c
src/libscotch/mesh_coarsen.c
src/libscotch/mesh_graph.c
src/libscotch/mesh_induce_sepa.c
src/libscotch/mesh_io.c
src/libscotch/mesh_io_habo.c
src/libscotch/mesh_io_scot.c
src/libscotch/order.c
src/libscotch/order_check.c
src/libscotch/order_io.c
src/libscotch/parser.c
src/libscotch/parser_ll.c
src/libscotch/parser_yy.c
src/libscotch/vgraph.c
src/libscotch/vgraph_check.c
src/libscotch/vgraph_separate_bd.c
src/libscotch/vgraph_separate_df.c
src/libscotch/vgraph_separate_es.c
src/libscotch/vgraph_separate_fm.c
src/libscotch/vgraph_separate_gg.c
src/libscotch/vgraph_separate_gp.c
src/libscotch/vgraph_separate_ml.c
src/libscotch/vgraph_separate_st.c
src/libscotch/vgraph_separate_th.c
src/libscotch/vgraph_separate_vw.c
src/libscotch/vgraph_separate_zr.c
src/libscotch/vgraph_store.c
src/libscotch/vmesh.c
src/libscotch/vmesh_check.c
src/libscotch/vmesh_separate_fm.c
src/libscotch/vmesh_separate_gg.c
src/libscotch/vmesh_separate_gr.c
src/libscotch/vmesh_separate_ml.c
src/libscotch/vmesh_separate_zr.c
src/libscotch/vmesh_separate_st.c
src/libscotch/vmesh_store.c
src/libscotch/wgraph.c
src/libscotch/wgraph_check.c
src/libscotch/wgraph_part_es.c
src/libscotch/wgraph_part_fm.c
src/libscotch/wgraph_part_gg.c
src/libscotch/wgraph_part_ml.c
src/libscotch/wgraph_part_rb.c
src/libscotch/wgraph_part_st.c
src/libscotch/wgraph_part_zr.c
src/libscotch/wgraph_store.c
)

add_library(scotcherr
src/libscotch/library_error.c
)

add_library(scotcherrexit
src/libscotch/library_error_exit.c
)
